<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width,initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
</head>
<body>
    <script>
    let str="https://www.baidu.com"
    if(str.startsWith("http://")){
        alert("普通网址")
    }else if(str.startsWith("https://")){
        alert("加密网址")
    }else if(str.startsWith("git://")){
        alert("git地址")
    }else{
        alert("其他")
    }
    let str1='a'
    let str2="b"
    //数据中使用较多
    let str3=`<h1>a${str2}</h1>`//ab
    </script>
</body>
</html>